package org.imaginedays.java.design.patter.observer;

import java.util.Observable;
import java.util.Observer;

public class Display extends Observable implements Observer {
	
	private String status = "未开";
	
	

	public String getStatus() {
		return status;
	}



	public void setStatus(String status) {
		this.status = status;
	}



	@Override
	public void update(Observable o, Object arg) {
         
	}
	
	public void displayTemperature(int temperature){
		if (temperature>100) {
//			this.setStatus("沸腾")；
			this.setChanged();
			this.notifyObservers(temperature);
		}
	}

}
